home *** CD-ROM | disk | FTP | other *** search
-
-
-
- aaaaddddddddttttoooopppp((((3333GGGG)))) aaaaddddddddttttoooopppp((((3333GGGG))))
-
-
-
- NNNNAAAAMMMMEEEE
- aaaaddddddddttttoooopppp - adds items to an existing pop-up menu
-
- FFFFOOOORRRRTTTTRRRRAAAANNNN 77777777 SSSSPPPPEEEECCCCIIIIFFFFIIIICCCCAAAATTTTIIIIOOOONNNN
- ssssuuuubbbbrrrroooouuuuttttiiiinnnneeee aaaaddddddddttttoooopppp((((ppppuuuupppp,,,, ssssttttrrrr,,,, lllleeeennnnggggtttthhhh,,,, aaaarrrrgggg))))
- iiiinnnntttteeeeggggeeeerrrr****4444 ppppuuuupppp
- cccchhhhaaaarrrraaaacccctttteeeerrrr****((((****)))) ssssttttrrrr
- iiiinnnntttteeeeggggeeeerrrr****4444 lllleeeennnnggggtttthhhh,,,, aaaarrrrgggg
-
- PPPPAAAARRRRAAAAMMMMEEEETTTTEEEERRRRSSSS
- _p_u_p expects the menu identifier of the menu to which you want to
- add. The menu identifier is the returned function value of the
- menu creation call to nnnneeeewwwwppppuuuupppp.
-
- _s_t_r expects the variable that contains the text that you want to add
- as a menu item. In addition, you have the option of pairing an
- "item type" flag with each menu item. There are seven menu item
- type flags:
-
- %%%%tttt marks item text as the menu title string.
-
- %%%%FFFF invokes a routine for every selection from this menu except
- those marked with a %n. You must specify the invoked
- routine in the _a_r_g parameter. The value of the menu item
- is used as a parameter of the executed routine. Thus, if
- you select the third menu item, the system passes 3 as a
- parameter to the function specified by %F.
-
- %%%%ffff invokes a routine when this particular menu item is
- selected. You must specify the invoked routine in the _a_r_g
- parameter. The value of the menu item is passed as a
- parameter of the routine. Thus, if you select the third
- menu item, the system passes 3 as a parameter to the
- routine specified by %f. If you have also used the %F flag
- within this menu, then the result of the %f routine is
- passed as a parameter of the %F routine.
-
- %%%%llll adds a line under the current entry. You can use this as a
- visual cue to group like entries together.
-
- %%%%mmmm pops up a menu whenever this menu item is selected. You
- must provide the menu identifier of the new menu in the _a_r_g
- parameter.
-
- %%%%nnnn like %f, this flag invokes a routine when the user selects
- this menu item. However, %n differs from %f in that it
- ignores the routine (if any) specified by %F. The value of
- the menu item is passed as a parameter of the executed
- routine. Thus, if you select the third menu item, the
- system passes 3 as a parameter to the function specified by
- %f.
-
-
-
-
- PPPPaaaaggggeeee 1111
-
-
-
-
-
-
- aaaaddddddddttttoooopppp((((3333GGGG)))) aaaaddddddddttttoooopppp((((3333GGGG))))
-
-
-
- %%%%xxxx_n assigns a numeric value to this menu item. This values
- overrides the default position-based value assigned to this
- menu item (e.g., the third item is 3). You must enter the
- numeric value as the _n part of the text string. Do not use
- the _a_r_g parameter to specify the numeric value.
-
- NNNNOOOOTTTTEEEE:::: If you use the vertical bar delimiter, "|", you can
- specify multiple menu items in a text string. However, because
- there is only one _a_r_g parameter, the text string can contain no
- more than one item type that references the _a_r_g parameter.
-
- _l_e_n_g_t_h expects the length of the string pointed to by the _s_t_r
- parameter.
-
- _a_r_g expects the command or submenu that you want to assign to the
- menu item. You can have only one _a_r_g parameter for each call to
- aaaaddddddddttttoooopppp. If the _a_r_g parameter is not needed, use 0 as a place
- holder.
-
- DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
- aaaaddddddddttttoooopppp adds items to the bottom of an existing pop-up menu. You can
- build a menu by using a call to nnnneeeewwwwppppuuuupppp to create a menu, followed by a
- call to aaaaddddddddttttoooopppp for each menu item that you want to add to the menu. To
- activate and display the menu, submit the menu to ddddooooppppuuuupppp.
-
- EEEEXXXXAAAAMMMMPPPPLLLLEEEE
- This example creates a menu with a submenu:
-
- submenu = newpup()
- call addtop(submen, 'rotate %f', 9, dorota)
- call addtop(submen, 'translate %f', 12, dotran)
- call addtop(submen, 'scale %f', 8, doscal)
- menu = newpup()
- call addtop(menu, 'sample %t', 9, 0)
- call addtop(menu, 'persp', 5, 0)
- call addtop(menu, 'xform %m', 8, submenu)
- call addtop(menu, 'greset %f', 9, greset)
-
-
- Because neither the "sample" menu title nor the "persp" menu item refer
- to the _a_r_g parameter, you can group "sample", "persp", and "xform" in a
- single call.
-
- call addtop(menu, 'sample %t | persp | xform %m', 28,
- + submenu)
-
-
- SSSSEEEEEEEE AAAALLLLSSSSOOOO
- dopup, freepup, newpup, setpup
-
-
-
-
-
-
- PPPPaaaaggggeeee 2222
-
-
-
-
-
-
- aaaaddddddddttttoooopppp((((3333GGGG)))) aaaaddddddddttttoooopppp((((3333GGGG))))
-
-
-
- NNNNOOOOTTTTEEEESSSS
- This routine is available only in immediate mode.
-
- When using the Distributed Graphics Library (DGL), you can not call other
- DGL routines within a function that is called by a popup menu, i.e. a
- function given as the argument to a %f or %F item type.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- PPPPaaaaggggeeee 3333
-
-
-
-